package com.hongding.sealcenter.vo;

import com.hongding.sealcenter.enums.SignAlgEnum;
import lombok.Data;

import java.io.Serializable;

/**
 * 申请PKCS10
 *
 * @author wang
 */
@Data
public class PkcsVO implements Serializable {
    /**
     * 证书DN
     */
    private String dn;
    /**
     * 密钥方式
     */
    private String secret;
    /**
     * algorithm 摘要算法 RSA:sha1 sha256 sha512  SM:sm3
     */
    private SignAlgEnum algorithm;

    private String pkcs8;
    private String pkcs10;
    private String pkcs12;
    /**
     * 证书信息
     */
    private String cert;
    /**
     * 证书密码
     */
    private String password;

    public PkcsVO() {
    }

    public PkcsVO(String dn, String secret, SignAlgEnum algorithm) {
        this.dn = dn;
        this.secret = secret;
        this.algorithm = algorithm;

    }

    public PkcsVO(String pkcs8, String pkcs10) {
        this.pkcs8 = pkcs8;
        this.pkcs10 = pkcs10;
    }

    public PkcsVO(String pkcs8, String pkcs10, String pkcs12) {
        this.pkcs8 = pkcs8;
        this.pkcs10 = pkcs10;
        this.pkcs12 = pkcs12;
    }
}
